<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page isELIgnored="false"%>
<%@ include file="../common/taglibs.jsp"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>交易查询</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
<link href="<c:url value="/css/a.css"/>" type="text/css" rel="stylesheet"/>
<link href="<c:url value="/css/index.css"/>" type="text/css" rel="stylesheet"/>
	<script type="text/javascript" src="<c:url value="/js/jquery-1.3.2.js" />"></script>   
	<script type="text/javascript" src="<c:url value="/js/common.js" />"></script>
	<script language="javascript" type="text/javascript" src="<c:url value="/js/My97DatePicker/WdatePicker.js"/>"></script>
	
	<style> 
　　　
　　　　　a {text-decoration:none} 
　　　　　a:hover {color: red;text-decoration:none} 
          a:VISITED {color: blue;}
　　
　　　</style> 

<script type="text/javascript"><!--
  $(document).ready(function(){
  		$("#edit_lh").click(function(){
 			
				     var len=$("#tableList").find(":checkbox[name=lh_list]:checked").length;	
				     var dd = $("input[name=lh_list]:checked");		
					if(len>0){
					    if(len==1){
					        var id = dd.val();
					        
						  	$("#queryUserForm").attr("action","edit_org.ct?code="+id);
						  	$("#queryUserForm").submit();
						  //return true;
					    }else{
					      alert('只能选择一个信息来进行操作！');
						  return false;
					    }			
					}else{
						alert('请选择要修改的信息！');
						return false;
					}		
			  }); 
			  $("#addOrg").click(function(){
			         	$("#queryUserForm").attr("action","addOrg.ct");
						$("#queryUserForm").submit();
			  });
  	    
         
  });
  </script>

	

  </head>
  
  <body>
   
       <div class="subpage">
	      <s:form id="queryUserForm" action="/org/search.ct" method="post"  theme="simple">
	    		
	    		<div class="user_title">
	    		 <h2 class="headline-inquires">POS收单运营管理平台<br /><span class="sub-title">
	    		 </span></h2>
	    		</div>
	    		<table width="100%" cellpadding="0" cellspacing="0" border="0" class="query_table">
	    		
	    		<tr><td colspan="4" align="center">
	    		 <h2 class="headline-inquires">机构管理<br /><span class="sub-title"></span></h2>
	    			
	    		</td></tr>
	    		
	    		
			    <tr><td colspan="4">&nbsp;</td></tr>
	    		
	    		
	           <tr>
				<td align="right">机构名称：</td><td align="left"  colspan="1">
					<s:textfield id="userNo"  name="orgSearchCondition.orgName"  cssClass="queryWidth"/>
				</td> 
				</tr>	
	            
				
				<tr><td colspan="4">&nbsp;</td></tr>
				<tr><td colspan="4" align="center">
				<s:submit value="查   询"/>
				&nbsp;&nbsp;&nbsp;&nbsp;
				<s:reset  value="取  消"/>&nbsp;&nbsp;&nbsp;&nbsp;
				<button id="edit_lh">修  改</button>&nbsp;&nbsp;&nbsp;&nbsp;
				<button id="addOrg">录 入</button>
				</td></tr>
				<tr><td colspan="4" align="right">
				
				&nbsp;&nbsp;&nbsp;&nbsp;
				
				</td></tr>
				
	    		<tr><td colspan="4">&nbsp;</td></tr>
	    		</table>
	    		<table width="100%" cellpadding="0" cellspacing="0" border="0">
	    		
	    		<tr><td colspan="4" align="center">
	    		 <h2 class="headline-inquires">机构信息列表</h2>
	    			
	    		</td></tr>
	    		<s:if test="searchRsList.size>0">
	             <tr><td  align="left">&nbsp;&nbsp;&nbsp;&nbsp;
					<page:pageCount max_pages="11" totalPage="${requestScope.totalPage}" currentPage="${requestScope.currentPage}" action="/ACCT/org/search.action?currentPage="/>
								
				</td></tr>  </s:if>
	    		</table>
	    		<table id="tableList" width="100%" class="table">
						<thead><tr>
							<th>操作</th><th>机构号码</th><th>机构名称</th><th>添加时间</th>
							</tr>
						</thead>
						<tbody>
						<s:iterator value="searchRsList" var="orgs">
							<tr>
							<td> 
								 
									<input id="<s:property value="#orgs.org_code"/>" value="<s:property value="#orgs.org_code"/>" style="display:none"/>
								<s:checkboxlist name="lh_list" list="#{#orgs.org_code:''}" theme="simple"></s:checkboxlist>
								 
							</td>
							<td> <s:property value="#orgs.org_code"/> </td>
							<td> <s:property value="#orgs.org_name"/> </td>
							<td> 	
								<fmt:formatDate value="${requestScope.orgs.dtCreate }" pattern="yyyy-MM-dd HH:mm:ss"/>
								 </td>
							
						    </tr>
						
						</s:iterator>
						
						
					</tbody>
				</table>
	    	</s:form>
	  </div>
	 	<s:if test="#request.info_request !=null">
	<script language="javascript">
	    alert("${request.info_request}");
	</script>
	</s:if>	
  </body>
</html>
